package com.swang.pms.dal;

import java.util.List;
import java.util.Map;

import com.swang.pms.model.dto.ManageUserDto;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import com.swang.pms.model.entity.ManageUser;
import com.swang.pms.model.dto.ManageUserDto;



/**
 * @ClassName: ManageUserDao
 * @Description: 用户服务Dao
 * @author 王泽
 * @date 2017年3月16日 下午9:45:51
 */
@Repository
public interface ManageUserDao {
    int deleteByPrimaryKey(Long id);

    int insertManagerUser(ManageUserDto record);

    int insertSelective(ManageUser record);

    ManageUserDto selectByPrimaryKey(Long id);

    int updateByPrimaryKeySelective(ManageUser record);

    int updateByPrimaryKey(ManageUser record);

    int countUserCode(String userCode);

    int deleteRoleOfManager(Long userId);

    int insertRoleOfManager(@Param("userId") Long userId, @Param("roleId") Long roleId);

    ManageUserDto selectsBySelf(String userName);

    List<Map<String, Object>> findPageDataByDto(ManageUserDto dto);

    int findPageDataCountByDto(ManageUserDto dto);

    List<ManageUser> listYunAdmin(ManageUser admin);

}
